<body class="gray-bg">
<div class="ibox-content">
    <form action="{:url('website/edit')}" method="post" class="form-horizontal">
        <input type="hidden" name="id" value="{$info['id']|default=''}">
        <div class="box">
            <div class="box-body">
                <div class="form-group">
                    <label class="col-sm-2 control-label">字段名称</label>
                    <div class="col-sm-10"><input class="form-control " name="name" placeholder="请输入配置名称"
                                                  value="{$info['name']|default=''}" type="text">
                        <span class="help-block m-b-none">（用于前台global调用，只能使用英文且不能重复）</span></div>
                </div>
                <div class="form-group">
                    <label class="col-sm-2 control-label">配置标题</label>
                    <div class="col-sm-10">
                        <input class="form-control " name="title" placeholder="请输入配置标题"
                               value="{$info['title']|default=''}" type="text">
                        <span class="help-block m-b-none">（用于后台显示的配置标题）</span></div>
                </div>
                <div class="form-group">
                    <label class="col-sm-2 control-label">配置类型</label>
                    <div class="col-sm-10">
                        <select name="type" class="form-control">
                            {volist name='type_list' id='type'}
                            <option value="{$key}"  {notempty name="info['type']"} {if condition="$info['type'] eq $key " }  selected="selected" {/if} {/notempty}>{$type}</option>
                            {/volist}
                        </select>
                        <span class="help-block m-b-none">（系统会根据不同类型解析配置值）</span>
                    </div>
                </div>
                <div class="form-group">
                    <label class="col-sm-2 control-label">配置分组</label>
                    <div class="col-sm-10">
                        <select name="group" class="form-control">
                            <option value="0">不分组</option>
                            {volist name='group_list' id='group'}
                            <option value="{$key}" {notempty name="info['group']"} {if condition="$info['group'] eq $key " }  selected="selected" {/if} {/notempty}>{$group}</option>
                            {/volist}
                        </select>
                        <span class="help-block m-b-none">（配置分组，不分组则不会显示在系统设置中）</span>
                    </div>
                </div>
                <div class="form-group">
                    <label class="col-sm-2 control-label">配置值</label>
                    <div class="col-sm-10">
                        <textarea class="form-control" name="value" rows="3" placeholder="请输入配置取值">{$info['value']|default=''}</textarea>
                        <span class="help-block m-b-none">（配置取值）</span>
                    </div>
                </div>
                <div class="form-group">
                    <label class="col-sm-2 control-label">配置项</label>
                    <div class="col-sm-10">
                        <textarea class="form-control" name="extra" rows="3" placeholder="请输入配置项">{$info['extra']|default=''}</textarea>
                        <span class="help-block m-b-none">（如果是枚举型 需要配置该项）</span>
                    </div>
                </div>
                <div class="form-group">
                    <label class="col-sm-2 control-label">描述信息</label>
                    <div class="col-sm-10">
                        <textarea class="form-control" name="describe" rows="3" placeholder="请输入描述信息">{$info['describe']|default=''}</textarea>
                        <span class="help-block m-b-none">（描述信息/备注）</span>
                    </div>
                </div>
                <div class="form-group">
                    <label class="col-sm-2 control-label">排序值</label>
                    <div class="col-sm-10">
                        <input class="form-control" name="sort" placeholder="请输入菜单排序值"
                               value="{$info['sort']|default='0'}" type="text">
                        <span class="help-block m-b-none">（用于分组显示的顺序，默认为 0）</span>
                    </div>
                </div>
            </div>
            <div class="form-group">
                <input type="hidden" name="id" value="{$info['id']|default='0'}"/>
                <div class="col-sm-offset-2 col-sm-8">
                    <button type="submit" class="btn  btn-info no-repeat-button ajax-post" data-style="slide-up"
                            target-form="form-horizontal" data-loading-text="Loading...">
                        <span class="ladda-label"><i class="fa fa-send"></i> 确 定 </span>
                    </button>
                </div>
            </div>
        </div>
    </form>
</div>